package Lab02.test19;

import java.util.Scanner;

public class Test {
    public static void main(String[] args) {

        System.out.println("请选择输出的模式【1小写；2大写】：");
        Scanner in=new Scanner(System.in);
        int choose=in.nextInt();
        System.out.println("请输入字符串：");
        Scanner inn=new Scanner(System.in);
        String str=inn.nextLine();
        StringBuffer sb=new StringBuffer(str);
        if(choose==1){
            System.out.println(sb.reverse().toString().toLowerCase());
        }else{
            System.out.println(sb.reverse().toString().toUpperCase());
        }
    }
}
